package com.example.remote;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(name = "inventory-nacos", path = "/inventory", fallback = InventoryServiceFallback.class)
public interface InventoryService {

    @GetMapping("/decreInventory.do")
    String decreInventory();

    @GetMapping("/deduct.do")
    Boolean deduct(@RequestParam("commodityCode") String commodityCode, @RequestParam("count") Integer count);

}
